package upc.condominio.edu.domain;

import org.springframework.roo.addon.entity.RooEntity;
import org.springframework.roo.addon.javabean.RooJavaBean;
import org.springframework.roo.addon.tostring.RooToString;
import upc.condominio.edu.domain.Vivienda;
import javax.persistence.ManyToOne;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;

import java.util.Calendar;
import java.util.Date;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
import org.springframework.format.annotation.DateTimeFormat;

@RooJavaBean
@RooToString
@RooEntity
public class Cuotas {

    @ManyToOne
    private Vivienda vivienda;

    @NotNull
    @Size(max = 20)
    private String periodo;

    @NotNull
    private Double importe;

    @NotNull
    @Temporal(TemporalType.TIMESTAMP)    
    @DateTimeFormat(style = "M-")
    private Calendar fecVencimiento;

    
}
